//为inputForm注册validate函数
			$("#userForm").validate({
				rules: {
					userName: {
						remote: ctx+ "/user/checkName.do?oldName=" + encodeURIComponent($("#oldName").val())
					},
					permissions:"required"
				},
				messages: {
					userName: {
						remote: "用户登录名已存在"
					}
				},
				errorContainer: "#messageBox",
				errorPlacement: function(error, element) {
					if ( element.is(":checkbox") )
						error.appendTo(element.parents("p").children("label").before());
					else
						error.insertAfter(element);
				}
			});